package cn.tedu.administration.controller;

import cn.tedu.administration.pojo.dto.GoodsParam;
import cn.tedu.administration.service.GoodsService;
import cn.tedu.base.response.JsonResult;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/v1/administration")
@Slf4j
public class GoodsController {
    @Autowired
    private GoodsService goodsService;
    @PostMapping("goods/application")
    public JsonResult addGoodsApplication(@RequestBody GoodsParam goodsParam){
        log.debug("传入的商品值：{}",goodsParam);
        goodsService.addGoodsApplication(goodsParam);
        return JsonResult.ok();
    }
}
